package com.forum.dto;

public class UserDetailDto {
    private Integer id;
    private String avatar;      // 来自 user_profile.avatar
    private String name;        // 来自 users.username
    private String bio;         // 来自 user_profile.description
    private String status;      // 根据 users.status 转换后，如 "正常"
    private Double balance;     // 如果当前登录用户与查询用户相同，返回真实余额；否则返回 0
    private String createAt;    // 用户创建时间（格式化字符串，例如 "2023-10-01"）
    private String email;
    private String lastLogin;   // 最后登录时间（格式化字符串）
    private Integer articleCount; // 该用户发表的文章数量
    private Integer followCount;  // 粉丝数：有多少人关注该用户
    private Integer likeCount;    // 该用户文章总点赞数
    private Integer myFollowCount; // 用户的关注数（该用户关注了多少人）
    private boolean isFollow; // 当前登录用户是否关注该用户

    public boolean isFollow() {
        return isFollow;
    }

    public void setFollow(boolean follow) {
        isFollow = follow;
    }

    // getters & setters
    public Integer getId() {
        return id;
    }
    public void setId(Integer id) {
        this.id = id;
    }
    public String getAvatar() {
        return avatar;
    }
    public void setAvatar(String avatar) {
        this.avatar = avatar;
    }
    public String getName() {
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }
    public String getBio() {
        return bio;
    }
    public void setBio(String bio) {
        this.bio = bio;
    }
    public String getStatus() {
        return status;
    }
    public void setStatus(String status) {
        this.status = status;
    }
    public Double getBalance() {
        return balance;
    }
    public void setBalance(Double balance) {
        this.balance = balance;
    }
    public String getCreateAt() {
        return createAt;
    }
    public void setCreateAt(String createAt) {
        this.createAt = createAt;
    }
    public String getEmail() {
        return email;
    }
    public void setEmail(String email) {
        this.email = email;
    }
    public String getLastLogin() {
        return lastLogin;
    }
    public void setLastLogin(String lastLogin) {
        this.lastLogin = lastLogin;
    }
    public Integer getArticleCount() {
        return articleCount;
    }
    public void setArticleCount(Integer articleCount) {
        this.articleCount = articleCount;
    }
    public Integer getFollowCount() {
        return followCount;
    }
    public void setFollowCount(Integer followCount) {
        this.followCount = followCount;
    }
    public Integer getLikeCount() {
        return likeCount;
    }
    public void setLikeCount(Integer likeCount) {
        this.likeCount = likeCount;
    }
    public Integer getMyFollowCount() {
        return myFollowCount;
    }
    public void setMyFollowCount(Integer myFollowCount) {
        this.myFollowCount = myFollowCount;
    }
}
